package com.hb.trade.server.project.section.service.raw;

import com.baomidou.mybatisplus.extension.service.IService;
import com.hb.core.pojo.parent.PageResult;
import com.hb.core.pojo.project.file.dto.BidFileInfoDTO;
import com.hb.core.pojo.project.section.dto.BidSectionTenderDTO;
import com.hb.core.pojo.project.section.entity.BidSection;
import com.hb.core.pojo.project.section.entity.BidSectionTender;

import java.util.List;

/**
 * <p>
 * 投标人投标信息 服务类
 * </p>
 *
 * @author admin
 * @since 2021-11-09
 */
public interface BidSectionTenderService extends IService<BidSectionTender> {

    /**
     * 根据投标人id查询投标信息
     *
     * @param sectionId 标段id
     * @param tenderId  投标人id
     * @return {@link BidSectionTender}
     * @author gaoyf
     * @date 2021-11-9
     */
    BidSectionTenderDTO getBySectionIdAndTenderId(Long sectionId, Long tenderId);

    /**
     * 根据标段id和企业id查询投标信息
     * @param sectionId
     * @param orgId
     * @return
     */
    BidSectionTenderDTO getBySectionIdAndOrgId(Long sectionId, Long orgId);

    /**
     * 获取投标信息列表
     *
     * @param bidSectionTender
     * @return
     */
    PageResult<BidSectionTenderDTO> listBidSectionTender(BidSectionTenderDTO bidSectionTender);

    /**
     * 根据标段Id查询投标人的登录用户名username
     *      (目前用于开标大厅消息构造消费者)
     *
     * @param sectionId
     * @return
     */
    List<String> getBidderUserNameBySectionId(Long sectionId);
    /**
     *
     * @Description: 获得当前标段解密成功的
     * @Author: zhongdl
     * @Date:2022/2/15 15:49
     * @param sectionId:
     * @return: {@link List< BidSectionTenderDTO> }
     **/
    List<BidSectionTenderDTO> listDecryptionBidSectionTender(Long sectionId,Integer status,Integer decryptFlag);


    /**
     * Description: 根据企业id和标段id查询投标列表
     * @author: fengbin
     * @date: 2022/2/28 16:25
     * @param orgId
     * @param sectionId
     @return: java.util.List<com.hb.core.pojo.project.section.entity.BidSection>
     */
    List<BidSectionTender> findSectionTenderInfoByOrgId(Long orgId , Long sectionId );

    /**
     * 保存投标文件信息
     * @param bidSectionTenderDTO
     * @return
     */
    Long saveTenderFileInfo(BidSectionTenderDTO bidSectionTenderDTO);

}
